#include <stdio.h>
#include <stdlib.h>

/* run this program using the console pauser or add your own getch, system("pause") or input loop */
char color = 'B';
void first(void);
void second(void);

int main(int argc, char *argv[])
{
	extern char color;
	printf("color in main() is %c\n", color);
	first();
	printf("color in main() is %c\n", color);
	second();
	printf("color in main() is %c\n", color);

	system("pause");
	return 0;
}

void first(void)
{
	char color;

	color = 'R';
	printf("color in main() is %c\n", color);
}

void second(void)
{
	extern char color;

	color = 'G';
	printf("color in main() is %c\n", color);
}